// Require the framework and instantiate it

// ESM
import Fastify from 'fastify'
import routes from './route/our-first-route.js'
const fastify = Fastify({
  logger: true
})
fastify.register(routes)

// CommonJs
// Declare a route

// Run the server!
fastify.listen({ port: 3000 }, function (err, address) {
  if (err) {
    fastify.log.error(err)
    process.exit(1)
  }
  // Server is now listening on ${address}
})